<div style='text-align:center;padding:12px;'>
	<table border="0" cellspacing="0" cellpadding="4">
		<tr>
			<td>Title:</td>
			<td><input type="text" id="dng_title" style="width:240px"/></td>
		</tr>
		<tr>
			<td>Description:</td>
			<td><input type="text" id="dng_comment" style="width:240px" /></td>
		</tr>
	</table>
	
</div>
<div style='text-align:center'>
	<button id="dng_accept" style='margin:4px;width:80px'>OK</button>
	<button id="dng_cancel" style='margin:4px;width:80px'>Cancel</button>
</div>
<script>

var item=Param.arg_photo;
dng_title.value=item.Title;
dng_comment.value=item.Comment||"";

dng_comment.focus();

dng_cancel.onclick=closedialog;

dng_accept.onclick=function()
{
	var title=dng_title.value;
	var comment=dng_comment.value;
	Browser.AsyncUpdatePhoto({CategoryID:item.CategoryID,PhotoID:item.PhotoID,Title:title,Comment:comment,Callback:function(ret){
		if(Browser.HandleError(ret))return true;
		alert("Updated!");
		closedialog();
	}});
}

</script>
